package demo.pattern.adapter;

/**
 * @author : GuoFei
 * @since : 2019/6/25 16:47
 */
public class ThreeElectricAdapter implements ThreeElectricOutlet {

    // 定义一个二向插座的引用对象
    TwoElectricOutlet outlet;

    // 构造函数
    ThreeElectricAdapter(TwoElectricOutlet outlet) {
        this.outlet = outlet;
    }

    @Override
    public void connectElectricCurrent() {
        //通过二相插座引用对象调用其具体方法，实现二相插座通电
        outlet.connectElectricCurrent();
    }

}
